package org.springframework.zp.introspect.bean;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * spring 当中各种注入的写法和区别对比
 */
@Slf4j(topic = "e")
@Component("a")
public class SpringBeanInfoTest {
	@Autowired
	AnnotationAutowiredFiledBeanTest autowiredFiledBeanTest;


	@Autowired
	public void setAnnotationAutowiredMethodBeanTest(AnnotationAutowiredMethodBeanTest annotationAutowiredMethodBeanTest){
		log.debug("*****  AnnotationAutowiredMethodBeanTest=[{}]",annotationAutowiredMethodBeanTest);
	}

	/**
	 * {@link org.springframework.zp.introspect.bfpp.UpdateBeanInfoBeanFactoryPostProcessor} 里面 设置 setAutowireMode=2 的
	 * 时候，该属性自动注入才会生效，否则默认不生效
	 *
	 * @param autowiredInjectByTypeMethodBeanTest
	 */
	public void setAutowiredInjectByTypeMethodBeanTest(AutowiredInjectByTypeMethodBeanTest autowiredInjectByTypeMethodBeanTest){
		log.debug("+++++ AutowiredInjectByTypeMethodBeanTest=[{}]",autowiredInjectByTypeMethodBeanTest);
	}

	public void setBeanDefinitionPropertyValuesBeanTest(BeanDefinitionPropertyValuesBeanTest beanDefinitionPropertyValuesBeanTest){
		log.debug("------ BeanDefinitionPropertyValuesBeanTest=[{}]",beanDefinitionPropertyValuesBeanTest);
	}

	//spring 注入
//	getC(){
//
//	}

	public void printf(){
		log.debug("###### autowiredFiledBeanTest=[{}]",autowiredFiledBeanTest);
	}

}
